using System.Runtime.InteropServices;

namespace WindowsAPI
{
    [StructLayout(LayoutKind.Explicit)]
    public struct Input
    {
        public static int Size { get { return Marshal.SizeOf(typeof(Input)); } }

        [FieldOffset(0)]
        public InputType type;

        [FieldOffset(sizeof(int))]
        public MouseInput Maouse;

        [FieldOffset(sizeof(int))]
        public KeyboardInput Keyboard;

        [FieldOffset(sizeof(int))]
        public HardwareInput Hardware;
    }

    public enum InputType
    {
        INPUT_MOUSE = 0,
        INPUT_KEYBOARD = 1,
        INPUT_HARDWARE = 2
    }
}